﻿using Volo.Abp.Modularity;
using Xms.Abp.Modularity;
using Xms.Abp.Storage;
using Xms.Abp.Storage.DependencyInjection;

namespace MemberManagement;

[DependsOn(
    typeof(MemberManagementDomainModule),
    typeof(XmsAbpStorageModule)
    )]
public class MemberManagementStorageModule : XmsModule
{
    public override void ConfigureServices(ServiceConfigurationContext context)
    {
        context.Services.AddStorage<MemberManagementStorage>(options =>
        {
            options.AddDefaultRepositories<IMemberManagementStorage>();

            //options.AddRepository<Tenant, EfCoreTenantRepository>();
        }, options =>
        {
            options.TablePrefix = MemberManagementDbProperties.DbTablePrefix;
            options.Schema = MemberManagementDbProperties.DbSchema;
        });
    }
}
